<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="js/jquery.1.8.js" type="text/javascript"></script>
    <script src="js/vue.js" type="text/javascript"></script>
    <link rel="stylesheet" href="css/home.css">
</head>
<body>
    <div id="app">
        <div class="top">
            微商城
        </div>
    

        <table>
            <tr>
                <td class="left">
                    <a href="user.html" target="content">我的</a>
                    <a href="vue-cart-master/cart.html" target="content">购物车</a>
                    <a href="login.html">退出登录</a>
                </td>
                <td>
                    <iframe name="content" src="user.html">

                    </iframe>
                </td>
            </tr>
        </table>
       
    </div>
    
</body>
<script>
    var vm=new Vue({
        el:'#app',
        data:{
            users: []
        },
        methods: {
            load(){
                // var student={loginName:'1',name:'gaojiayao',pwd:'123456'}
                
            }
        },
        created(){
            var that=this;
                $.get("http://api.tutestudio.net/api/getUser",'',function(res){
                    console.log(res)
                    var json=res.data;
                    for(var i=0;i<json.length;i++){
                        that.users.push(json[i])
                    }
                })
                this.users.push(student)

        }
    })
</script>
</html>